package com.zhihuishu.micro.course.openapi.manager;

import java.util.List;
import java.util.Map;

import com.zhihuishu.micro.course.openapi.manager.dto.AppCourseInfoDto;
import com.zhihuishu.micro.course.openapi.manager.dto.ChapterWebDto;
import com.zhihuishu.micro.course.openapi.manager.dto.CourseOpenDto;
import com.zhihuishu.micro.course.openapi.manager.dto.CoursePendingAuditDto;
import com.zhihuishu.micro.course.openapi.manager.dto.CourseStatusDto;
import com.zhihuishu.micro.course.openapi.manager.dto.CourseTimePlanOpenDto;
import com.zhihuishu.micro.course.openapi.manager.dto.CourseUpdateTimeDto;
import com.zhihuishu.micro.course.openapi.manager.dto.CourseVideoDto;
import com.zhihuishu.micro.course.openapi.manager.dto.MeetCourseDto;
import com.zhihuishu.remote.RemoteException;
import com.zhihuishu.remote.RemoteResult;

/**
 * 课程远程接口
 * 
 * @author yulijin
 * @date 2016年3月16日 下午2:29:45
 */
public interface ManagerCourseOpenService {

    /**
     * 查询课程审计内容
     * 
     * @param count
     * @return
     * @throws RemoteException
     */
    RemoteResult<List<CourseOpenDto>> findCourseOpenDtos(int count) throws RemoteException;

    /**
     * 更新审计课程内容
     * 
     * @param count
     * @return
     * @throws RemoteException
     */
    RemoteResult<Boolean> updateCourseOpenDtos(List<CourseOpenDto> courseOpenDtoList) throws RemoteException;

    /**
     * 查询待审核课程总数量
     * 
     * @author ztl
     * @param courseName
     * @return
     * @throws RemoteException
     */
    RemoteResult<Integer> findPendingAuditCourseAmount(String courseName) throws RemoteException;

    /**
     * 查询待审核课程信息列表
     * 
     * @author ztl
     * @param courseName
     * @param pageNo
     * @param pageSize
     * @return
     * @throws RemoteException
     */
    RemoteResult<List<CoursePendingAuditDto>> findPendingAuditCourseDtos(String courseName, int pageNo,
            int pageSize) throws RemoteException;

    /**
     * 查询审计章节信息
     * 
     * @param count
     * @return
     * @throws RemoteException
     */
    RemoteResult<List<ChapterWebDto>> findChapterList(Long courseId) throws RemoteException;

    /**
     * 查询总数
     * 
     * @author ylj
     * @param keywords
     * @param userId
     * @return
     * @throws RemoteException
     */
    RemoteResult<Integer> findCourseDtoTotalCount(String keywords, Long userId) throws RemoteException;

    /**
     * 查询课程信息分页
     * 
     * @author ylj
     * @param keywords
     * @param pageNo
     * @param pageSize
     * @param userId
     * @return
     * @throws RemoteException
     */
    RemoteResult<List<CourseOpenDto>> findPageCourseDtos(String keywords, int pageNo, int pageSize,
            Long userId) throws RemoteException;

    /**
     * 根据课程ids查询课程进度
     * 
     * @author ylj
     * @param count
     * @return
     * @throws RemoteException
     */
    RemoteResult<Map<Long, Integer>> findProgressByCourseIds(List<Long> courseIds) throws RemoteException;

    /**
     * 根据课程id查询课程计划
     * 
     * @author yulijin
     * @date 2016年7月19日 上午9:02:55
     * @param courseId
     * @return
     * @throws RemoteException
     */
    RemoteResult<List<CourseTimePlanOpenDto>> findCourseTimePlanByCourseId(Long courseId)
            throws RemoteException;

    /**
     * 根据课程id查询课程信息
     * 
     * @author yulijin
     * @date 2016年7月19日 上午9:10:13
     * @param courseId
     * @return
     * @throws RemoteException
     */
    RemoteResult<CourseOpenDto> findCourseOpenByCourseId(Long courseId) throws RemoteException;

    /**
     * 
     * @discription 根据课程id集合查询课程列表的完成状态
     * @author jipeng
     * @created 2016年8月30日 下午4:13:30
     * @param courseIds
     * @return
     * @throws RemoteException
     */
    RemoteResult<Map<Long, CourseStatusDto>> findCoursesStatus(List<Long> courseIds);

    /**
     * 根据课程ID集合查询建课更新状态列表
     * 
     * @author ztl
     * @param courseIds
     * @return
     * @throws RemoteException
     */
    RemoteResult<List<CourseUpdateTimeDto>> findCourseUpdateTime(List<Long> courseIds) throws RemoteException;

    /**
     * 根据课程ID集合查询建课课程章节视频列表
     * 
     * @author ztl
     * @param courseIds
     * @return
     * @throws RemoteException
     */
    RemoteResult<List<CourseVideoDto>> findCourseVideo(List<Long> courseIds) throws RemoteException;

    /**
     * 根据课程ID查询课程见面课列表
     * 
     * @author ztl
     * @param courseId
     * @return
     * @throws RemoteException
     */
    RemoteResult<List<MeetCourseDto>> findMeetCourse(Long courseId) throws RemoteException;

    /**
     * 根据课程ID查询课程章节
     * 
     * @author ztl
     * @param courseId
     * @return
     * @throws RemoteException
     */
    RemoteResult<List<ChapterWebDto>> findChapterAndLessonByCourseId(Long courseId) throws RemoteException;

    /**
     * 查询总数
     * 
     * @author ylj
     * @param keywords
     * @return
     * @throws RemoteException
     */
    RemoteResult<Integer> findAppCourseInfoTotalCount(String keywords) throws RemoteException;

    /**
     * 查询课程信息分页
     * 
     * @author ylj
     * @param keywords
     * @param pageNo
     * @param pageSize
     * @return
     * @throws RemoteException
     */
    RemoteResult<List<AppCourseInfoDto>> findPageAppCourseInfoDtos(String keywords, int pageNo, int pageSize)
            throws RemoteException;
}
